Let the sscanf based timestamps be additive on a read.
authorrobertl <robertl>
Fri, 28 Dec 2007 05:43:07 +0000 (05:43 +0000)
committerrobertl <robertl>
Fri, 28 Dec 2007 05:43:07 +0000 (05:43 +0000)
csv_util.c

index f5dd1df8a53050e173177b2da664347e6c9d9521..437b8d1723f5c338b5d75b9eb91908be9415a2df 100644 (file)
@@ -1019,10 +1019,10 @@ xcsv_parse_val(const char *s, waypoint *wpt, const field_map_t *fmp)
        wpt->creation_time = yyyymmdd_to_time(s);
        break;
     case XT_GMT_TIME:
-       wpt->creation_time = sscanftime(s, fmp->printfc, 1);
+       wpt->creation_time += sscanftime(s, fmp->printfc, 1);
        break;
     case XT_LOCAL_TIME:
-       wpt->creation_time = sscanftime(s, fmp->printfc, 0);
+       wpt->creation_time += sscanftime(s, fmp->printfc, 0);
        break;
     /* Useful when time and date are in separate fields 
        GMT / Local offset is handled by the two cases above */